<!DOCTYPE html>
<html class="login-page">
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>微众云商通体验版系统管理后台</title>
	    <link type="text/css" rel="stylesheet" media="all" href="/static/css/base.css">
	    <link type="text/css" rel="stylesheet" media="all" href="/static/lib/bootstrap-3.3.6/css/bootstrap.min.css">
	    <link type="text/css" rel="stylesheet" media="all" href="/static/css/login.css">
    </head>
    <body class="loginBg">
        <div id="topbar">
	        <div id="global-nav">
		        <div id="weixin-logo"><img src="/static/img/logo/logo.png"></div>
	        </div>
        </div>

        <div id="front-card">
	        <div id="front-welcome">
		        <div id="front-signin">
			        <form action="/account/logined_account/?_method=put" method="post">
				        <div class="form-group ml20 mr20 mt20">
				    		<label class="login-name">
				        		<input class="form-control mt5" id="username" name="username" type="text" placeholder="用户名">
				        	</label>
				        	<label class="login-pwd">
				        		<input class="form-control mt5" id="password" name="password" type="password" placeholder="密码">
				        	</label>  
				        </div>
				        <div style="text-align: right;" class="mt20 mb10 mr10">
				            <input type="submit" class="login-btn" value="登  录"/>
				            <div class="logining-btn"><img src="/static/img/logo/loading.gif">登录中...</div>
				        </div>
				        <div class="ml20 mr20 errorInfo">
                            {% if errorMsg %}
                            <div class="error-info">{{errorMsg}}</div>{% endif %}
                        </div>
			        </form>
		        </div>
	        </div>
        </div>
        
        <script type="text/javascript" src="/static/lib/jquery/jquery-1.12.2.min.js"></script>
        <script type="text/javascript">
        	//登录
        	$("form").submit(function(e){
				$('.login-btn').css({display:'none'});
				$('.logining-btn').css({display:'block'});
			});
	        $(document).ready(function() {
		        //错误提示
				var $error = $('.errorInfo');
				if('{{errorMsg}}'){
					$('.login-btn').css({display:'none'});
					$error.css({display:'block'});
				}
                //重新输入
                $('#username,#password').keyup(function() {
                    $error.css({display:'none'});
                    $('.login-btn').css({display:'block'});
                });

                
	        });
        </script>
	</body>
</html>
